<?php

namespace App\Admin\Controllers;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\App;

class SwitchingLanguageController extends Controller
{
    protected function switch(Request $request)
    {
        session()->put('language', $request->all()['language']);
        return response()->json([
            'message' => '成功',
            'code' => 200
        ], 200);
    }
}
